package cn.edu.scau.cmi.chenzehan.singlepattern;

public class President {

	private String name;
	private static President  president = null;
	private President() {
		
	}
	private President(String name) {
		this.name=name;
	}
    public static  boolean addPresident(String name) {
		if(president == null) {
			president = new President(name);
			return true;
		}
		else return false;
	}
    public static void setPresidentEmpty() {
    	president = null;
    }
}
